#ifndef _SERVEUR_H
#define _SERVEUR_H

#include "traitement.h"


typedef struct log_client{
  char *ip;
  char *nom;
  char *date_connexion;
  char *requete;
  char *code_retour;
  char *user_agent;
}log_client;


extern void  get_page          (int sock,requete_t requete, log_client *log);
extern void  deconnecter_client_thread(int indice);
extern void  deconnecter_client_select(int indice);
extern void  copier_fichier    (int fd_dst,int fd_src);
extern void  envoyer_chaine    (int isock, char *chaine);
extern void  envoyer_code      (int isock, char *code,log_client *logc,char *url);
extern void  gerer_client      (int indice);

extern void perror_and_exit_whenever(int assertion);

#endif
